﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="dep_user_list.aspx.cs" Inherits="Xnjc_dep_user_list" %>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head  runat="server">
    <title>部门工作人员列表</title>
    <link href="../css/page.css" rel="stylesheet" type="text/css" />
</head>

    <script language="Javascript">

        function mouseMove(trname) {
            return;
            var hidden3 = document.getElementById("hidden3");
            hidden3.value = trname.style.backgroundColor;
            trname.style.backgroundColor = '#caf7fd';
        }
        function mouseOut(trname) {
            return;
            var hidden3 = document.getElementById("hidden3");
            trname.style.backgroundColor = hidden3.value;
        }
    </script>

    <script>
        function selectUser(box, userid, username) {
            if (box.checked)
                parent.frames["leftFrame"].addUser(userid, username);
            else
                parent.frames["leftFrame"].removeUserById(userid);
        }

        function boxSelectSwitch(c) {
            var useridBoxex = document.forms["xxxxxxx"].userid;
            if (!useridBoxex.length) {
                useridBoxex = [useridBoxex];
            }
            for (var i = 0; i < useridBoxex.length; i++) {
                useridBoxex[i].checked = c;
                selectUser(useridBoxex[i], useridBoxex[i].value, useridBoxex[i].username);
            }
        }
    </script>
<body>
    <!--所有或在某个时间段内，在某个岗位上，所有人的岗位执行情况-->
    <form name="xxxxxxx">
        <table width="100%" cellspacing="0" cellpadding="0" align="center" border="0" class="tab">
            <tr>
                <th>
                    <input type="checkbox" onclick="boxSelectSwitch(this.checked)" /></th>
                <th>
                    姓名</th>
            </tr>
            <%
                foreach (System.Data.DataRow m in dtUsers.Rows)
                {
                    String userid = m["USERID"].ToString();
                    String username = m["USER_NAME"].ToString();
            %>
            <tr>
                <td>
                    <input type="checkbox" name="userid" value="<%=userid%>" username="<%=username%>"
                        onclick="selectUser(this,'<%=userid%>','<%=username%>')" />
                </td>
                <td>
                    <%=username%>
                </td>
            </tr>
            <%
                }
            %>
        </table>
    </form>
</body>
</html>